<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');?>
<?php $this->load->view('common/head');?>
<body class="no-skin">
<?php $this->load->view('common/header');?>
<div class="main-container" id="main-container">
    <script type="text/javascript">
        try {
            ace.settings.check('main-container', 'fixed')
        } catch (e) {
        }
    </script>

    <?php $this->load->view('common/sidebar');?>
    <div class="main-content">
        <div class="main-content-inner">
            <!-- #section:basics/content.breadcrumbs -->
            <?php $this->load->view('common/breadcrumbs');?>

            <!-- /section:basics/content.breadcrumbs -->
            <div class="page-content">

                <?php $this->load->view('common/set');?>

                <!-- /section:settings.box -->
                <div class="row">
                    <?php if($member['user_group'] ==3 || $member['user_group'] ==5){?>
                    <div class="col-xs-12 col-sm-3 center">
                        <div>
                            <span class="profile-picture">
                                <img id="avatar" style="width: 180px;height: 180px;" class="editable img-responsive" alt="Alex's Avatar" src="<?php echo base_url('uploads/'.$uid.'/qrcode/'.$uid.'_qrcode.png');?>">
                            </span>
                            <div class="space-4"></div>
                            <div class="width-80 label label-info label-xlg arrowed-in arrowed-in-right">
                                <div class="inline position-relative">
                                    <a href="#" class="user-title-label dropdown-toggle" data-toggle="dropdown">
                                        <i class="icon-circle light-green middle"></i>
                                        &nbsp;
                                        <span class="white"><a class="white" href="<?php echo base_url('uploads/'.$uid.'/qrcode/'.$uid.'_qrcode.png');?>" download="推广码.png">专属二维码下载</a></span>
                                    </a>
                                </div>
                            </div>
                        </div>

                        <div class="space-6"></div>

                        <div class="hr hr12 dotted"></div>

                        <div class="hr hr16 dotted"></div>
                    </div>
                    <?php }?>
                    <div class="col-xs-12 col-sm-9">
                        <!-- PAGE CONTENT BEGINS -->
                        <form class="form-horizontal" action="<?php echo site_url(X_URL.'personal/update');?>" method="post">
                            <div class="form-group">
                                <label class="col-sm-1 control-label no-padding-right" for="form-field-1"> 用户名 </label>
                                <div class="col-sm-9">
                                    <input type="text"
                                        <?php if(isset($member) && $member['user_id'] == 1){ ?>
                                            readonly
                                        <?php }else{?>
                                            name="user"
                                        <?php } ?>
                                           class="rcol-xs-10 col-sm-5" value="<?php if(isset($member)){ echo $member["user_name"];}?>">
                                    <input type="hidden" name="user_id" value="<?php if(isset($member)){ echo $member["user_id"];}?>">
                                    <span class="help-inline col-xs-12 col-sm-7">
											<?php if(isset($member) && $member['user_id'] == 1){ ?><span class="middle">无法修改</span><?php } ?>
											</span>
                                </div>
                            </div>

                            <div class="space-4"></div>

                            <div class="form-group">
                                <label class="col-sm-1 control-label no-padding-right" for="form-field-2"> 用户密码 </label>
                                <div class="col-sm-9">
                                    <input type="password" name="user_password" id="user_password" placeholder="用户密码"
                                           class="col-xs-10 col-sm-5" value="">
                                    <span class="help-inline col-xs-12 col-sm-7">
												<span class="middle">留空不修改</span>
											</span>
                                </div>
                            </div>

                            <div class="space-4"></div>

                            <div class="space-4"></div>

                            <div class="col-md-offset-2 col-md-9">
                                <button class="btn btn-info" type="submit">
                                    <i class="icon-ok bigger-110"></i>
                                    提交
                                </button>

                                &nbsp; &nbsp; &nbsp;
                                <button class="btn" type="reset">
                                    <i class="icon-undo bigger-110"></i>
                                    重置
                                </button>
                            </div>
                        </form>
                        <!-- PAGE CONTENT ENDS -->
                    </div><!-- /.col -->
                </div><!-- /.row -->
            </div><!-- /.page-content -->
        </div>
    </div><!-- /.main-content -->
    <?php $this->load->view('common/footer');?>
</div><!-- /.main-container -->

<?php $this->load->view('common/footerjs');?>
<!-- inline scripts related to this page -->
</body>
</html>
